<td>
										  <?php 
include'connecsi.php'; 
$dokter_id=$_POST[dokter_id];
$tgldaf=$_POST[tgldaf];
$nmps=$_POST[nmps];
$jk=$_POST[jk];
$almt=$_POST[almt];
$umurps=$_POST[umurps];
$telpps=$_POST[telpps];
$kiriman=$_GET[kiriman];
?>
										  <div align="center"><font color="#000000" size="4"><strong>EDIT DATA PASIEN DENGAN KODE</strong>  <? echo"$kiriman"; ?></font></div>
										  <br>
<table width="61%" align="center" border="0" cellspacing="1" cellpadding="1">
  <tr>
	<td colspan="3">
	<?php
	if($_GET[aksi]=="ubah")
	{
		if((empty($poli)) or (empty($nmdok))  or (empty($jk)) or (empty($almt)) or (empty($telp)))							
		{echo "<script>alert('Lengkapi Form')</script>";
			echo"<meta http-equiv=refresh content=0;URL='edit_dokter1.php?kiriman=$kiriman'>";}
			elseif(!ctype_alpha($poli))							{echo "<script>alert('Poli Diisi Hanya Huruf')</script>";
			echo"<meta http-equiv=refresh content=0;URL='edit_dokter1.php?kiriman=$kiriman'>";}
			elseif(!is_numeric($telp))							{echo "<script>alert('Telp Diisi Hanya Angka')</script>";
			echo"<meta http-equiv=refresh content=0;URL='edit_dokter1.php?kiriman=$kiriman'>";}
		else
		{
		$proses_3="update db_pasien set NAMA_DOKTER='$nmdok',POLI='$poli',JNSKLMIN_DOKTER='$jk',ALAMAT_DOKTER='$almt',NOTLP_DOKTER='$telp' where ID_DOKTER='$kiriman' ";
		$queri_3=mysql_query($proses_3)or die("maaf inputtan gagal");
		if($queri_3)
		{
		echo "<script>alert('Data Update')</script>";echo"<meta http-equiv=refresh content=0;URL='index.php?ling=dokter'>";
		}
		}
	}	
	?>
	</td>
  </tr>
  <form action="edit_dokter1.php?kiriman=<? echo"$kiriman"; ?>&aksi=ubah" method="post">
  <?php
  $bukalah=mysql_query("select * from dokter where ID_DOKTER='$kiriman' ");
  while($hasilnya=mysql_fetch_array($bukalah)) {
  ?>
  <tr>
	<td height="27"><div align="left">Poli</div></td>
	<td align="center"><div align="center"><strong>:</strong></div></td>
	<td><input type="text" size="30" maxlength="35" name="poli" value="<? echo"$hasilnya[POLI]"; ?>"></td>
  </tr>
  <tr>
	<td width="36%" height="26" align="left">Nama Dokter </td>
	<td width="2%" align="left"><div align="center"><strong>:</strong></div></td>
	<td width="62%"><input type="text" name="nmdok" size="30" value="<? echo"$hasilnya[NAMA_DOKTER]"; ?>"></td>
  </tr>
  <tr>
	<td width="36%" height="22" align="left">Jenis Kelamin </td>
	<td width="2%" align="left"><div align="center"><strong>:</strong></div></td>
	<td width="62%"><select name="jk" id="jk">
				<option value="<? echo"$hasilnya[JNSKLMIN_DOKTER]"; ?>"><? echo"$hasilnya[JNSKLMIN_DOKTER]"; ?></option>
                <option value="L">L</option>
                <option value="P">P</option>
              </select></td>
  </tr>
  <tr>
	<td width="36%" height="27" align="left">Alamat</td>
	<td width="2%" align="center"><div align="center"><strong>:</strong></div></td>
	<td width="62%"><input type="text" name="almt" size="30" value="<? echo"$hasilnya[ALAMAT_DOKTER]"; ?>"></td>
  </tr>
  <tr>
	<td width="36%" height="26" align="left">No Telp </td>
	<td width="2%" align="left"><div align="center"><strong>:</strong></div></td>
	<td width="62%"><input type="text" name="telp" size="15" maxlength="15" value="<? echo"$hasilnya[NOTLP_DOKTER]"; ?>"></td>
  </tr>
   <tr>
	<td>&nbsp;</td>
	<td>&nbsp;</td>
	<td>&nbsp;</td>
  </tr>
  <tr>
	<td colspan="3" align="center"><p>
	  <input type="submit" name="aksi" value="Edit">
	</p>
</td>
  </tr>
  <? } ?>
  </form>
</table>
										     </td>
